<div>
  <%= form.label :links %>
</div>
<div>
  <%= cocooned_container id: "cocooned-links", data: {controller: "cocooned"} do %>
    <%= form.fields_for :links do |f| %>
      <%= render "link_fields", f: f %>
    <% end %>
  <% end %>
  <div>
    <%= cocooned_add_item_button t(".add"), form, :links,
          class: "btn btn-secondary",
          insertion_node: "#cocooned-links",
          insertion_method: "append" %>
  </div>
</div>
